<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>Getting Started</title>
<link rel="stylesheet" href="../../../boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="../../../index.html" title="ODTONE 0.3">
<link rel="up" href="../mihf_index.html" title="ODTONE-MIHF">
<link rel="prev" href="../mihf_index.html" title="ODTONE-MIHF">
<link rel="next" href="mihf_internal_arch.html" title="MIHF Internal Architecture">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr><td valign="top"><img alt="'ODTONE - Open Dot Twenty One'" width="100" height="100" src="../../.././images/logo.png"></td></tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../mihf_index.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../mihf_index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="mihf_internal_arch.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
<div class="section" title="Getting Started">
<div class="titlepage"><div><div><h4 class="title">
<a name="odtone.app.mihf_index.mihf_getStart"></a><a class="link" href="mihf_getStart.html" title="Getting Started"> Getting Started</a>
</h4></div></div></div>
<div class="section" title="Configuration">
<div class="titlepage"><div><div><h5 class="title">
<a name="odtone.app.mihf_index.mihf_getStart.configuration"></a><a class="link" href="mihf_getStart.html#odtone.app.mihf_index.mihf_getStart.configuration" title="Configuration">Configuration</a>
</h5></div></div></div>
<p>
            For now the MIHFs capabilities are read from configuration files. Future
            versions will inquire the available Link SAPs for the required information.
            There are other parameters that can be configured either using an configuration
            file or passing them directly in command line.
          </p>
<pre class="programlisting"><span class="identifier">MIHF</span> <span class="identifier">Configuration</span> <span class="identifier">Options</span><span class="special">:</span>
   <span class="special">--</span><span class="identifier">help</span>                               <span class="identifier">Display</span> <span class="identifier">configuration</span> <span class="identifier">options</span>
   <span class="special">--</span><span class="identifier">conf</span><span class="special">.</span><span class="identifier">file</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="identifier">odtone</span><span class="special">.</span><span class="identifier">conf</span><span class="special">)</span>       <span class="identifier">Configuration</span> <span class="identifier">File</span>
   <span class="special">--</span><span class="identifier">conf</span><span class="special">.</span><span class="identifier">recv_buff_len</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">4096</span><span class="special">)</span>     <span class="identifier">Receive</span> <span class="identifier">Buffer</span> <span class="identifier">Length</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">id</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="identifier">mihf</span><span class="special">)</span>                <span class="identifier">MIHF</span> <span class="identifier">Id</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">ip</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">127.0</span><span class="special">.</span><span class="number">0.1</span><span class="special">)</span>           <span class="identifier">MIHF</span> <span class="identifier">Ip</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">peers</span> <span class="identifier">arg</span>                     <span class="identifier">List</span> <span class="identifier">of</span> <span class="identifier">peer</span> <span class="identifier">MIHFs</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">remote_port</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">4551</span><span class="special">)</span>       <span class="identifier">MIHF</span> <span class="identifier">Remote</span> <span class="identifier">Communications</span> <span class="identifier">Port</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">local_port</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">1025</span><span class="special">)</span>        <span class="identifier">MIHF</span> <span class="identifier">Local</span> <span class="identifier">Communications</span> <span class="identifier">Port</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">link_response_time</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">100</span><span class="special">)</span> <span class="identifier">MIHF</span> <span class="identifier">Link</span> <span class="identifier">Response</span> <span class="identifier">waiting</span> <span class="identifier">time</span> <span class="special">(</span><span class="identifier">milliseconds</span><span class="special">)</span>
   <span class="special">--</span><span class="identifier">mihf</span><span class="special">.</span><span class="identifier">link_delete</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">2</span><span class="special">)</span>          <span class="identifier">MIHF</span> <span class="identifier">Link</span> <span class="identifier">Response</span> <span class="identifier">fails</span> <span class="identifier">to</span> <span class="keyword">delete</span> <span class="identifier">the</span> <span class="identifier">Link</span> <span class="identifier">SAP</span>
   <span class="special">--</span><span class="identifier">enable_broadcast</span>                   <span class="identifier">MIHF</span> <span class="identifier">responds</span> <span class="identifier">to</span> <span class="identifier">broadcast</span> <span class="identifier">messages</span>
   <span class="special">--</span><span class="identifier">log</span> <span class="identifier">arg</span> <span class="special">(=</span><span class="number">1</span><span class="special">)</span>                       <span class="identifier">MIHF</span> <span class="identifier">log</span> <span class="identifier">level</span> <span class="special">[</span><span class="number">0</span><span class="special">-</span><span class="number">4</span><span class="special">]</span>
</pre>
<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../../doc/html/images/note.png"></td>
<th align="left">Note</th>
</tr>
<tr><td align="left" valign="top">
<p>
              <span class="bold"><strong>List of peer MIHF's</strong></span>
            </p>
<p>
              Comma separated list of remote MIHF's. If you want to test remote MIHF
              communication add an entry here with the IP address of the remote MIHF.
            </p>
<p>
              Usage: &lt;mihf id&gt; &lt;ip&gt; &lt;port&gt;
            </p>
</td></tr>
</table></div>
<a name="odtone.app.mihf_index.mihf_getStart.configuration.example"></a><h6>
<a name="id3099108"></a>
            <a class="link" href="mihf_getStart.html#odtone.app.mihf_index.mihf_getStart.configuration.example">Example</a>
          </h6>
<p>
            Automatic remote peer MIHF discovery is not yet implemented, so you need
            to add the remote MIHF's IP address and port number to the configuration
            file. Edit the file and add an entry to peers in the form: &lt;mihf_id&gt;
            &lt;ip&gt; &lt;port&gt; where &lt;mihf_id&gt; is the identifier of the
            remote MIHF, &lt;ip&gt; and &lt;port&gt; are the IP address and port
            of the remote MIHF.
          </p>
<div class="note" title="Note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../../../../doc/html/images/note.png"></td>
<th align="left">Note</th>
</tr>
<tr><td align="left" valign="top"><p>
              You need to edit the configuration file on both machines
            </p></td></tr>
</table></div>
<p>
            On the machine with the mihf1 the configuration file can look like:
          </p>
<pre class="programlisting"><span class="special">[</span><span class="identifier">mihf</span><span class="special">]</span>
<span class="identifier">id</span> <span class="special">=</span> <span class="identifier">mihf1</span>
<span class="identifier">local_port</span> <span class="special">=</span> <span class="number">1025</span>
<span class="identifier">remote_port</span> <span class="special">=</span> <span class="number">4551</span>
<span class="identifier">peers</span> <span class="special">=</span> <span class="identifier">mihf2</span> <span class="special">&lt;</span><span class="identifier">mihf1_IP_address</span><span class="special">&gt;</span> <span class="number">4551</span>
</pre>
<p>
            On the machine with the mihf2 the configuration file can look like:
          </p>
<pre class="programlisting"><span class="special">[</span><span class="identifier">mihf</span><span class="special">]</span>
<span class="identifier">id</span> <span class="special">=</span> <span class="identifier">mihf2</span>
<span class="identifier">local_port</span> <span class="special">=</span> <span class="number">1025</span>
<span class="identifier">remote_port</span> <span class="special">=</span> <span class="number">4551</span>
<span class="identifier">peers</span> <span class="special">=</span> <span class="identifier">mihf1</span> <span class="special">&lt;</span><span class="identifier">mihf2_IP_address</span><span class="special">&gt;</span> <span class="number">4551</span>
</pre>
</div>
<div class="section" title="Running">
<div class="titlepage"><div><div><h5 class="title">
<a name="odtone.app.mihf_index.mihf_getStart.running"></a><a class="link" href="mihf_getStart.html#odtone.app.mihf_index.mihf_getStart.running" title="Running">Running</a>
</h5></div></div></div>
<p>
            The ODTONE-MIHF must be executed passing directly, in command line, the
            location of the configuration file.
          </p>
<p>
            E.g.: ./odtone-mihf --conf.file=./src/mihf/odtone.conf
          </p>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright &#169; 2009 -2011 Universidade Aveiro<br>Copyright &#169; 2009 -2011 Instituto de Telecomunica&#231;&#245;es - P&#243;lo Aveiro<p>
        This software is distributed under a license. The full license agreement
        can be found in the LICENSE in this distribution. This software may not be
        copied, modified, sold or distributed other than expressed in the named license
        agreement. This software is distributed without any warranty.
      </p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../mihf_index.html"><img src="../../../../../doc/html/images/prev.png" alt="Prev"></a><a accesskey="u" href="../mihf_index.html"><img src="../../../../../doc/html/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../doc/html/images/home.png" alt="Home"></a><a accesskey="n" href="mihf_internal_arch.html"><img src="../../../../../doc/html/images/next.png" alt="Next"></a>
</div>
</body>
</html>
